﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Consumable.aspx.cs" Inherits="WebUI.LabManage.Consumable" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <ext:PageManager runat="server" ID="PageManager1" AutoSizePanelID="Panel1" />
    <ext:Panel runat="server" ID="Panel1" BodyPadding="5px" EnableBackgroundColor="true"
        ShowBorder="false" Layout="Anchor" ShowHeader="true" Title="易耗品管理">
        <Items>
            <ext:Form runat="server" ID="Form2" LabelWidth="90px" Height="74px" EnableBackgroundColor="true"
                ShowHeader="false" ShowBorder="true" BodyPadding="10px" AutoWidth="true">
                <Toolbars>
                    <ext:Toolbar runat="server" ID="Toolbar1">
                        <Items>
                            <ext:Button runat="server" ID="bn_search" Text="查询" Icon="Reload" Type="Submit" OnClick="bnSearch_Click">
                            </ext:Button>
                            <ext:ToolbarSeparator runat="server">
                            </ext:ToolbarSeparator>
                            <ext:Button runat="server" ID="bn_reset" Text="重置" Icon="ArrowIn" Type="Reset" OnClick="bnReset_Click">
                            </ext:Button>
                            <ext:ToolbarFill runat="server">
                            </ext:ToolbarFill>
                            <ext:Button runat="server" ID="bn_add" Text="新增" Icon="Add" Type="Button">
                            </ext:Button>
                        </Items>
                    </ext:Toolbar>
                </Toolbars>
                <Rows>
                    <ext:FormRow>
                        <Items>
                            <ext:TextBox runat="server" ID="tb_name" Label="易耗品名" TabIndex="1">
                            </ext:TextBox>
                            <ext:DropDownList runat="server" ID="dl_location" Label="所属地点" TabIndex="2">
                            </ext:DropDownList>
                        </Items>
                    </ext:FormRow>
                </Rows>
            </ext:Form>
            <ext:Grid runat="server" ID="Grid1" AnchorValue="100% -84px" ShowHeader="false" EnableBackgroundColor="true"
                EnableRowNumber="true" AllowPaging="true" OnPageIndexChange="Grid1_PageIndexChange"
                DataKeyNames="id" PageSize="25" OnRowDoubleClick="Grid1_RowClick" EnableRowDoubleClick="true"
                OnRowCommand="Grid1_RowCommand">
                <Columns>
                    <ext:BoundField DataField="name" HeaderText="易耗品名" Width="200px" />
                    <ext:BoundField DataField="normal" HeaderText="正常数量" Width="90px" />
                    <ext:BoundField DataField="bad" HeaderText="故障数量" Width="90px" />
                    <ext:BoundField DataField="stock" HeaderText="库存数量" Width="90px" />
                    <ext:BoundField DataField="value" HeaderText="所属地点" Width="180px" />
                    <ext:BoundField DataField="remarks" HeaderText="备注" Width="220px" />
                    <ext:WindowField ColumnID="viewField" HeaderText="管理" Width="50px" WindowID="view_window" Icon="Zoom" DataIFrameUrlFormatString="ConsumableEdit.aspx?action=view&id={0}"
                        DataIFrameUrlFields="id" DataWindowTitleFormatString="管理 - 易耗品：{0}" DataWindowTitleField="name" DataTextFormatString="{0}"  ToolTip="查看易耗品库存记录"/>
                        <ext:WindowField ColumnID="editField" HeaderText="编辑" Width="50px" WindowID="window1" Icon="BulletEdit" DataIFrameUrlFormatString="ConsumableEdit.aspx?action=edit&id={0}"
                        DataIFrameUrlFields="id" DataWindowTitleFormatString="编辑 - 易耗品：{0}" DataWindowTitleField="name" DataTextFormatString="{0}"  ToolTip="修改易耗品参数"/>
                        <ext:LinkButtonField Icon="TableDelete" HeaderText="删除" Width="50px" ToolTip="删除" ConfirmText="确认删除？" CommandName="Del" />
                </Columns>
            </ext:Grid>
        </Items>
    </ext:Panel>
    <ext:Window runat="server" ID="window1" Popup="false" EnableIFrame="true" Title="易耗品信息管理"
        IFrameUrl="about:blank" Target="Top" IsModal="true" Width="680px" Height="400px"
        EnableAjaxLoading="true"></ext:Window>
        <ext:Window runat="server" ID="view_window" Popup="false" EnableIFrame="true" Title="易耗品信息管理"
        IFrameUrl="about:blank" Target="Top" IsModal="true" Width="680px" Height="580px"
        EnableAjaxLoading="true"></ext:Window>
    </form>
</body>
</html>
